<?php
// +----------------------------------------------------------------------+
// | Author:  Evgeny Leontev <eleontev@gmail.com>                         |
// | Copyright (c) 2005 Evgeny Leontev                                    |
// +----------------------------------------------------------------------+
// | This source file is free software; you can redistribute it and/or    |
// | modify it under the terms of the GNU Lesser General Public           |
// | License as published by the Free Software Foundation; either         |
// | version 2.1 of the License, or (at your option) any later version.   |
// |                                                                      |
// | This source file is distributed in the hope that it will be useful,  |
// | but WITHOUT ANY WARRANTY; without even the implied warranty of       |
// | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU    |
// | Lesser General Public License for more details.                      |
// +----------------------------------------------------------------------+

class BaseView extends BaseApp
{
	
	var $encoding;
	
	
	// old one
	//function getFormatedDate($timestamp, $format = 'M d, Y') {
	//	return date($format, $timestamp); 
	//}
	
	
	function _getFormatedDate($timestamp, $format = '%d %b, %Y') {
		
		//$timestamp = (strpos($timestamp, '-') !== false) ? strtotime($timestamp) : $timestamp;
		$timestamp = (is_numeric($timestamp)) ? $timestamp : strtotime($timestamp);
		return strftime($format, $timestamp); 
	}
	
	
	function isExtra($module) {
		return $this->extra[$module];
	}
	
	
	function &stripVars($values, $skip_keys = array(), $server_check = 'display') {
		return RequestDataUtil::stripVars($values, $skip_keys, $server_check);
	}
}
?>